<template>
  <div>
    <div style="margin: 10px 0 20px 0;font-size: 30px;font-weight: bold">{{ problem.title }}</div>
    <div style="margin: 10px 0;font-size: 13px;color: #666">{{problem.author}}  <span style="margin-left: 20px">{{problem.time}}</span></div>
    <div style="box-shadow: 0 2px 4px rgba(0,0,0, .12);padding: 10px">
      <div v-html="problem.content" ></div>
    </div>
  </div>
</template>

<script>
export default {
  name: "ProblemDetail",
  data() {
    return {
      problem: {}
    }
  },
  created() {
    let id = this.$route.query.id
    if (!id ){
      return
    }
    this.$request.get('/problem/selectById/' + id).then(res=>{
      this.problem = res.data
    })
  },
  methods: {}
}
</script>

<style scoped>

</style>